/**
 * 创建员工服务
 * @param {*} params
 * @returns
 */
const createDeviceModel = function (params) {
  return fetch("/api/v1/device-model/create?" + new Date().getTime(), { 
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    body: JSON.stringify(params),
  });
};
/**
 * 获取设备模型列表服务
 * @param {*} params
 * @returns
 */
const getDeviceModel = function (params) {
  return fetch("/api/v1/device-model/list?" + new Date().getTime(), {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    body: JSON.stringify(params),
  });
};
/**
 * 编辑设备模型服务
 * @param {*} params
 * @returns
 */
const updateDeviceModel = function (params) {
  return fetch("/api/v1/device-model/update?" + new Date().getTime(), {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    body: JSON.stringify(params),
  });
};
/**
 * 删除设备模型服务
 * @param {*} params
 * @returns
 */
const deleteDeviceModel = function (params) {
  return fetch("/api/v1/device-model/delete?" + new Date().getTime(), {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    body: JSON.stringify(params),
  });
};
export default {
  createDeviceModel,
  getDeviceModel,
  updateDeviceModel,
  deleteDeviceModel,
};
